<!doctype html>
<html>
<head>
	<meta charset="utf-8">
	<title>选择维修厂-去保养-氦修驿站旗下品牌</title>
    <meta name="keywords" content="汽车保养,汽车配件,汽车维修,养车无忧,养车,4S店品质,氦修驿站,丰田保养" />
    <meta name="description" content="100%正品配件,4S店一半价格,先行赔付,闪电送达!线上购买配件,线下提供安装.上万用户的最佳选择!去掉中间环节,直接从源头采购配件!" />
	<link rel="stylesheet" type="text/css" href="{:C('WEB_URL')}Public/css/base.css">
    <link rel="stylesheet" type="text/css" href="{:C('WEB_URL')}Public/css/baoyang.css">
</head>
<body>

    <include file="Public:header" />

    <div id="wrap">
        <div class="title">
            <h2>预约保养</h2>
            <p class="step">
                <em>1、选择车型</em><i>&#xe606;</i>
                <em>2、选择服务</em><i>&#xe606;</i>
                <em class="current">3、选择维修厂</em><i>&#xe606;</i>
                <em>4、确认信息</em>
            </p>
        </div>
        <div class="companyList">
            <p class="txt fs14 mb20">请选择维修厂为您的爱车进行保养</p>
            <ul>
                <volist name="company" id="vo">
                <li data-id="{$vo['wx_id']}">
                    <img src="http://app2.haixiuyizhan.com/{$vo['headImage']}" alt="">
                    <p class="name" title="{$vo['name']}">{$vo['wx_name']}</p>
                    <p class="star">
                        <php>for($i=0;$i<round($vo['average']);$i++){echo "<i class='orange'>&#xe609;</i>";}</php>
                        <php>for($i=0;$i<5-round($vo['average']);$i++){echo "<i>&#xe609;</i>";}</php>

                    </p>
                    <p class="address">{$vo['address']}</p>
                    <i class="selected">&#xe60f;</i>
                </li>
                </volist>
            </ul>

            <p class="clearfix mt20"></p>
            <form action="{:U('step4')}" id="J_myForm" method="post">
                
                <div class="page">
                    {$page}
                </div>
                <div class="btn clearfix">
                    <a href="javascript:void(0)" class="btnSubmit" id="J_btnSubmit">下一步</a>
                    <a href="javascript:void(0)" onclick="window.history.go(-1)" class="back">返回</a>
                </div>
                <input name="wx_id" type="hidden" value="" id="J_wx_id" />
            </form>
            
            
        </div>
    </div>
    <include file="Public:footer" />
    <include file="Public:loginReg" />
    <script type="text/javascript" src="{:C('WEB_URL')}Public/js/baseFn.js"></script>
    <script type="text/javascript" src="{:C('WEB_URL')}Public/js/My97DatePicker/WdatePicker.js"></script>

    <script>
    $(".companyList").children("ul").on("click",function(e){
        var element=e.target.tagName==="LI"?$(e.target):$(e.target).parents("li");
        element.addClass("current").siblings("li").removeClass("current");
        setCookie("wx_id",element.attr("data-id"));
    })

    $("#J_btnSubmit").on("click",function(){
        var wx_id=getCookie("wx_id"),
            time=$("#J_time").val(),
            house=$("#J_house > option:selected").val();

        if(!wx_id){
            alert("请选择一家您中意的维修厂");
            return false;
        }else if(time==""){
            alert("请输入预约时间");
            return false;
        }else if(house==""){
            alert("请选择具体时间段");
            return false;
        }

        $("#J_wx_id").val(wx_id);
        $("#J_myForm").submit();

    })
    </script>

</body>
</html>